﻿<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>

<%
    String nav_path = request.getContextPath();
    String nav_basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+nav_path+"/";
%>
<!-- 侧边菜单 -->
<div class="layui-side layui-side-menu">
    <div class="layui-side-scroll">
        <div class="layui-logo" lay-href="<%=nav_basePath%>manager/console.action">
            <span id="system_title">网站设置</span>
        </div>
        <ul class="layui-nav layui-nav-tree" lay-shrink="all" id="LAY-system-side-menu" lay-filter="layadmin-system-side-menu">
            <li data-name="home" class="layui-nav-item layui-nav-itemed">
                <a href="javascript:;" lay-href="<%=nav_basePath%>manager/console.action" lay-tips="控制台" lay-direction="2" class="layui-this">
                    <i class="layui-icon layui-icon-home"></i>
                    <cite>控制台</cite>
                </a>
            </li>
            <c:forEach var="permissionPermission" items="${permissionPermissions}" varStatus="status">
                <c:if test="${permissionPermission.pid == 0}">
                    <c:set var="subPermissionPermissionsCount" value="0"/>
                    <c:forEach var="subPermissionPermissions" items="${permissionPermissions}">
                        <c:if test="${(subPermissionPermissions.pid == permissionPermission.id)&&subPermissionPermissions.type!=3}">
                            <c:set var="subPermissionPermissionsCount" value="${subPermissionPermissionsCount+1}"/>
                        </c:if>
                    </c:forEach>
                    <c:if test="${subPermissionPermissionsCount==0}">
                        <%--隐藏短信服务  2019.01.07--%>    <c:if test="${permissionPermission.name!='短信服务'}">
                        <li data-name="app" class="layui-nav-item system_menus system_${permissionPermission.systemId} ${status.index}" <c:if test="${permissionPermission.systemId != 1}">style="display:none;"</c:if>>
                            <a href="javascript:;" lay-href="<%=nav_basePath%>${permissionPermission.uri}" lay-tips="${permissionPermission.name}" lay-direction="2">
                                <i class="${permissionPermission.icon}"></i>
                                <cite>${permissionPermission.name}</cite>
                            </a>
                        </li>
                        </c:if>
                    </c:if>
                    <c:if test="${subPermissionPermissionsCount!=0}">
                        <li data-name="app" class="layui-nav-item system_menus system_${permissionPermission.systemId} ${status.index}" <c:if test="${permissionPermission.systemId != 1}">style="display:none;"</c:if>>
                            <a href="javascript:;" lay-tips="${permissionPermission.name}" lay-direction="2">
                                <i class="${permissionPermission.icon}"></i>
                                <cite>${permissionPermission.name}</cite>
                            </a>
                            <dl class="layui-nav-child">
                                <c:forEach var="subPermissionPermissions" items="${permissionPermissions}">
                                    <c:if test="${subPermissionPermissions.pid == permissionPermission.id}">

                                        <dd>
                                            <a lay-href="<%=nav_basePath%>${subPermissionPermissions.uri}">${subPermissionPermissions.name}</a>
                                        </dd>
                                    </c:if>
                                </c:forEach>
                            </dl>
                        </li>

                    </c:if>

                </c:if>

            </c:forEach>
        </ul>
    </div>
</div>
